import { Pipe, PipeTransform } from '@angular/core';

@Pipe({
  name: 'getMethod',
})
export class MethodPipe implements PipeTransform {
  transform(value: number) {
    if (value === 1) {
      return 'GET';
    }
    if (value === 2) {
      return 'POST';
    }
    if (value === 3) {
      return 'PUT';
    }
    if (value === 4) {
      return 'DELETE';
    }
  }
}
